home *** CD-ROM | disk | FTP | other *** search
/ New Star Software Collection / NSS_Collection.iso / 3-170 dbase 10 for windows / 1.ima / SAMPLES.PAK / PICTURES.PRG < prev    next >
Text File  |  1993-07-26  |  2KB  |  75 lines

  1. *******************************************************************************
  2. *  PROGRAM:      SightSnd.prg
  3. *
  4. *  WRITTEN BY:   Borland Late Night Crew
  5. *
  6. *  DATE:         7/20/93
  7. *
  8. *  UPDATED:
  9. *
  10. *  VERSION:      Alpha α
  11. *
  12. *  DESCRIPTION:  This program shows how Bladerunner's window objects defined
  13. *                on database fields are related and change as the record pointer
  14. *                changes.  It also displays Bladerunner's imaging and sound
  15. *                commands.
  16. *                A window is displayed containing a listbox of image names, and
  17. *                the image corresponding to the highlighted listbox prompt.
  18. *                This image is retrieved from a database memo field
  19. *                (pictures->bitmap).  Pressing the Sound button, or double
  20. *                clicking anywhere in the window will play the sound
  21. *                corresponding to the current image.  This sound is a .wav
  22. *                file also stored in a databased memo field (pictures->sound).
  23. *                Selecting the "Exit" menu choice, and then the "Exit" pulldown
  24. *                choice closes the window.
  25. *
  26. *  PARAMETERS:   None
  27. *
  28. *  CALLS:        None
  29. *
  30. *  USAGE:        DO SightSnd
  31. *
  32. *
  33. *
  34. *******************************************************************************
  35.  
  36. private savearea
  37. savearea = str(workarea())
  38.  
  39.  
  40. define font RomanBI        height 35 width 27 type "Roman" Bold Italic
  41. define font Modern          height 18 width 15 type "Modern" Bold
  42. define font CourierBI       height 20 width 20 type "Courier" Bold Italic
  43.  
  44. use pictures in select()
  45. select pictures
  46.  
  47. define window pictures from 0,0 to 33,78 of application;
  48.    sizeable moveable ;
  49.    color bg/b
  50.  
  51. define menu choice exit of pictures prompt "File"
  52. define pulldown exit
  53. define pulldown choice 1 of exit prompt "E&xit"
  54. on menu choice exit of pictures activate pulldown exit
  55. on selection pulldown exit close window pictures
  56.  
  57. define text title of pictures at 1,19 prompt "Sights and Sounds";
  58.    color gr+/n font RomanBI
  59. define pushbutton sound of pictures at 5,1 prompt "Sound" font Modern
  60. define listbox things of pictures prompt field pictures->name;
  61.    from 12,2 to 25,15
  62.  
  63. define image picture of pictures memo bitmap from 3,20 to 30,75
  64. on selection window pictures play sound memo pictures->sound
  65. * make this window modal
  66. readmodal("pictures")
  67.  
  68. * Clean up
  69. use
  70. select &savearea
  71. return
  72.  
  73.  
  74.  
  75.